package com.zr.model;
// Generated 2016-6-19 19:35:13 by Hibernate Tools 3.2.2.GA

import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * TIncome generated by hbm2java
 */
@Entity
@Table(name = "t_income", catalog = "ld_sys")
public class TIncome implements java.io.Serializable {

	private Integer iid;
	private Double insure;
	private Double postage;
	private Double amount;
	private Set<TOrder> TOrders = new HashSet<TOrder>();

	public TIncome() {
	}

	public TIncome(Double insure, Double postage, Double amount, Set<TOrder> TOrders) {
		this.insure = insure;
		this.postage = postage;
		this.amount = amount;
		this.TOrders = TOrders;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)

	@Column(name = "iid", unique = true, nullable = false)
	public Integer getIid() {
		return this.iid;
	}

	public void setIid(Integer iid) {
		this.iid = iid;
	}

	@Column(name = "insure", precision = 255, scale = 0)
	public Double getInsure() {
		return this.insure;
	}

	public void setInsure(Double insure) {
		this.insure = insure;
	}

	@Column(name = "postage", precision = 255, scale = 0)
	public Double getPostage() {
		return this.postage;
	}

	public void setPostage(Double postage) {
		this.postage = postage;
	}

	@Column(name = "amount", precision = 255, scale = 0)
	public Double getAmount() {
		return this.amount;
	}

	public void setAmount(Double amount) {
		this.amount = amount;
	}

	@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "TIncome")
	public Set<TOrder> getTOrders() {
		return this.TOrders;
	}

	public void setTOrders(Set<TOrder> TOrders) {
		this.TOrders = TOrders;
	}

}
